Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
pynmeagps Pull Request Template
ENHANCEMENTS:
Enhance NMEAMessage to parse unrecognised* NMEA sentence types to a nominal
<NMEA(TTXXX, NOMINAL, field_01=x...)>
message structure ifVALMSGID
validation flag is not set, rather than raise aNMEAParseMessage
error e.g.:A. with the
VALMSGID
flag not set (the new default behaviour):from pynmeagps import NMEAReader msg = NMEAReader.parse("$GNACN,103607.00,ECN,E,A,W,A,test,C*67\r\n") print(msg)
B. with the
VALMSGID flag
set:from pynmeagps import NMEAReader, VALMSGID msg = NMEAReader.parse("$GNACN,103607.00,ECN,E,A,W,A,test,C*67\r\n", validate=VALMSGID) print(msg)
* unrecognised message types include those with unknown or invalid NMEA msgIDs (but valid payloads and checksums), or valid NMEA sentences whose payload definitions are not yet in the public domain (e.g. those currently commented-out in
NMEA_MSGIDS
).Add NMEA ALF sentence definition.
Add
validate
argument toNMEAMessage
and carry forward fromNMEAReader
Add logger to
NMEAMessage
.Testing
Please test all changes, however trivial, against the supplied pytest suite
tests/test_*.py
. Please describe any test cases you have amended or added to this suite to maintain >= 99% code coverage.Checklist:
tests/test_*.py
unittest suite to maintain >= 99% code coverage.tests/test_*.py
unittest suite.